chore: sync develop to main — PostHog migration verification - #204
Conversation
…rver card, OAuth discovery, and llms.txt - Add Link response headers for agent discovery (RFC 8288): api-catalog, oauth-protected-resource, mcp-server-card, auth-md, llms-txt - Rewrite .well-known/api-catalog to RFC 9727 linkset+json format - Create .well-known/mcp/server-card.json with serverInfo schema (SEP-1649), replacing old .well-known/mcp.json - Add .well-known/oauth-authorization-server referencing Supabase issuer - Add .well-known/oauth-protected-resource (RFC 9728) - Add /llms.txt machine-readable site description for AI agents - Fix auth.md heading to match Auth.md standard - Add CORS Access-Control-Allow-Origin: * on all .well-known/* paths - Add <main> wrapper to LandingPage for semantic HTML - Document manual Cloudflare steps: DNS-AID records + Markdown for Agents
feat(agent-readiness): make Bayan Flow discoverable and usable by AI agents
…ompliance - Add service-desc, service-doc, describedby Link headers (RFC 8288) - Update api-catalog Content-Type with RFC 9727 profile parameter - Add A2A required fields to agent-card.json (version, skills, supportedInterfaces) - Create .well-known/mcp.json at scanner-expected path - Add Cloudflare Worker for Accept: text/markdown content negotiation - Add markdown summary files for all public pages - Update wrangler.jsonc with Worker entry point and assets binding
feat: Agent readiness — Link headers, markdown negotiation, A2A/MCP compliance
…tics - Replace Umami with PostHog SDK (posthog-js, @posthog/react) - Add PostHog reverse proxy via e.bayanflow.com (ad-blocker resilient) - Instrument 20+ custom events across VisualizerApp, UserMenu, SignInPromptModal, useFavorites, useNoteAutosave - Implement user identification on sign-in/sign-out via AuthProvider - Add first-party session replay (text/media masked, inputs masked) - Respect Do Not Track header - Add feature flag architecture for future use - Update CSP headers for PostHog domains - Update privacy policy, SECURITY.md to reference PostHog - Add VITE_POSTHOG_API_KEY/VITE_POSTHOG_API_HOST to CI workflows
…cache guards, dev bypass - deploy-cloudflare.yml: use branch-conditional proxy host (e.bayanflow.com for main, e.dev.bayanflow.com for develop) - public/_headers: add e.bayanflow.com and e.dev.bayanflow.com to connect-src - scripts/cspHeaders.js: exact token matching instead of substring includes; add proxy origin check - worker/index.js: accept both staging and production proxy domains; restrict static-asset cache to GET - worker/posthog-proxy.js: restrict static-asset cache to GET - src/services/analytics.js: set isBypassed flag to prevent SDK event queueing in dev - src/contexts/AuthProvider.jsx: identifyUser after profile fetch with accurate plan - .env.example: alphabetical ordering of PostHog env vars
feat(analytics): migrate from Umami to PostHog for SaaS product analytics
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
Contribution workflow
main: This PR mergesdevelopintomainfor PostHog migration verification.developwith full CI gates.Description
Production sync — pushing PostHog analytics migration and agent readiness updates to
mainto verify the Umami → PostHog migration works in production.8 commits across 3 merged PRs (#201–#203), touching analytics infrastructure and agent discovery.
Type of Change
Related Issues
Supersedes PRs #201–#203 merged into
develop.Changes Made
PostHog Analytics Migration (PR #203)
worker/posthog-proxy.js) to bypass ad-blockersPostHogProviderwith lazy initialization and feature flag supportanalytics.jsservice layer andanalyticsEvents.jsevent catalogAgent Readiness (PRs #201–#202)
.well-known/agent-card.json, MCP server card, and API catalog for AI agent discovery/llms.txtand/auth.mdTesting
pnpm test:run)Test Results
All PRs were gated by CI (lint → format → test:coverage → build) before merge to
develop.Code Quality
pnpm lint)pnpm format)Performance Impact
Accessibility
Breaking Changes
Checklist
Additional Notes
This is a targeted production sync to verify the PostHog analytics migration works end-to-end in production. v0.5.0 development continues on
develop.PRs included in this merge:
Post-deployment verification checklist:
/ph/...)Reviewer Guidelines: